package wqh.pojo;


import wqh.domain.Channel;

public class ChannelCover2 {

    private Integer id;
    private String name;
    private String ip;
    private Byte channel;
    private Byte type;
    private String unit;
    private String geo1;
    private String geo2;
    private String geo3;
    private String data;

    public ChannelCover2(Channel c, String geo1, String geo2, String geo3) {
        this.id = c.getId();
        this.name = c.getName();
        this.ip = c.getIp();
        this.channel = c.getChannel();
        this.type = c.getType();
        this.unit = c.getUnit();
        this.geo1 = geo1;
        this.geo2 = geo2;
        this.geo3 = geo3;
        this.data ="IP" + IPConver.Ip2Int(this.ip) +"-"+ this.channel;
    }

    @Override
    public String toString() {
        return "ChannelCover2{" +
                "id=" + id +
                ", name='" + name + '\'' +
                ", ip='" + ip + '\'' +
                ", channel=" + channel +
                ", type=" + type +
                ", unit='" + unit + '\'' +
                ", geo1='" + geo1 + '\'' +
                ", geo2='" + geo2 + '\'' +
                ", geo3='" + geo3 + '\'' +
                ", data='" + data + '\'' +
                '}';
    }

    public String getData() {
        return data;
    }

    public void setData(String data) {
        this.data = data;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getIp() {
        return ip;
    }

    public void setIp(String ip) {
        this.ip = ip;
    }

    public Byte getChannel() {
        return channel;
    }

    public void setChannel(Byte channel) {
        this.channel = channel;
    }

    public Byte getType() {
        return type;
    }

    public void setType(Byte type) {
        this.type = type;
    }

    public String getUnit() {
        return unit;
    }

    public void setUnit(String unit) {
        this.unit = unit;
    }

    public String getGeo1() {
        return geo1;
    }

    public void setGeo1(String geo1) {
        this.geo1 = geo1;
    }

    public String getGeo2() {
        return geo2;
    }

    public void setGeo2(String geo2) {
        this.geo2 = geo2;
    }

    public String getGeo3() {
        return geo3;
    }

    public void setGeo3(String geo3) {
        this.geo3 = geo3;
    }
}
